using System;
using System.Collections.Generic;
using System.Text;
using SDMX_Common = SDMX_ML.Framework.Common;

namespace SDMX_ML.Framework.Generic
{
    public class ValueType
    {
        private SDMX_Common.IDType _concept;
        private string _value;
        private string _starttime;

        public ValueType(string value, string concept)
        {
            if (!String.IsNullOrEmpty(value) & !String.IsNullOrEmpty(concept))
            {
                _value = value;
                _concept = new SDMX_Common.IDType(concept);
            }
            else
            {
                throw new Exception("Value and Concept is required in ValueType.");
            }
        }

        public ValueType(string value, SDMX_Common.IDType concept)
        {
            if (!String.IsNullOrEmpty(value) != null & concept != null)
            {
                _value = value;
                _concept = concept;
            }
            else
            {
                throw new Exception("Value and Concept is required in ValueType.");
            }
        }


        public SDMX_Common.IDType Concept
        {
            get { return _concept; }
            set { _concept = value; }
        }

        public string Value
        {
            get { return _value; }
            set { _value = value; }
        }

        public string StartTime
        {
            get { return _starttime; }
            set { _starttime = value; }
        }
    }
}
